Repository navigation
Deepen the engine’s legal actions and refusals - #56
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Single-card candidates carry the hand slot and card type that floor guidance uses. A Recovery can cover a standing Call after a Move. Once the Call is covered, the remaining Recovery shows the Stumble refusal.
Evidence
Execution evidence
./node_modules/.bin/vitest run packages/engine/tests/refusals.test.ts -t 'publishes floor guidance for a card added'Before the review fix —
1 failedwithError: Missing content for mov_999.After the review fix —
1 passed | 14 skipped.legalActions,floorRefusals, andlessonRefusalsmatched master atdc93688across 6,146 role Snapshots from 96 seeded games. The comparison covered both roles, content with and without Calls, each phase, both terminal states, all three lesson sources, and 775 no-op undo submissions.npm testpassed 404 tests, including the reducer properties, Snapshot refusals and visibility, client turn intent, and the existing golden replays.npm run lintandnpm run typecheckpassed.ENGINE_VERSIONis 6.Test seams
snapshotForandapplyActionfor Recovery cover and Stumble guidance.snapshotForwith a schema-valid addition to the bundled card catalog for the Spec regression.legalActionsandsnapshotForfor the one-off master comparison.Merge Danger
Door — Two-way. The reducer and resume envelope keep their existing contracts.
Blast radius — Engine.
Unaddressed findings
Standards
None. The single-card association now lives on its candidate.
Spec
None. The floor projection classifies cards from the supplied catalog, and the reproduced error has a regression test.
Security
None. The shared candidate inventory derives only from the viewer's own hand, the public market and supply, and published move history; the reducer stays the authority through
applyAction. A seeded-game check found no partner hand or draw card named inlegalActions,floorRefusals, orlessonRefusals, and every advertised action carried the viewer's role and applied cleanly, at both828b885and merge basedc93688.Review coverage
Both reviewers read all five changed files. Unread changed files and generated-output exclusions are empty.
Closes #55
Built with codex codex-cli 0.172.0 · gpt-6.2-sol · xhigh
Security review outcome
No unaddressed introduced findings.